package com.ikun.admin.modules.gen.entity;

import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.IdType;
import java.time.LocalDateTime;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import java.io.Serializable;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

/**
 * <p>
 * 用户建表实体类 用于用户网页生成表的实体
 * </p>
 *
 * @author ${author}
 * @since 2024-04-03
 */
@Data
@EqualsAndHashCode(callSuper = false)
@TableName("gen_table_entity")
@ApiModel(value="TableEntity对象", description="用户建表实体类 用于用户网页生成表的实体")
public class TableEntity implements Serializable {

    private static final long serialVersionUID=1L;

    @ApiModelProperty(value = "id")
    @TableId(value = "id", type = IdType.ASSIGN_ID)
    private Long id;

    @ApiModelProperty(value = "表id")
    private Long tableId;

    @ApiModelProperty(value = "字段名")
    private String fieldName;

    @ApiModelProperty(value = "字段类型 (查询字段类型表的value)")
    private String fieldValue;

    @ApiModelProperty(value = "备注")
    private String remark;

    @ApiModelProperty(value = "默认值")
    private String defaultValue;

    @ApiModelProperty(value = "主键标识 (0表示主键)")
    private Integer primKey;


    @ApiModelProperty(value = "长度")
    private String typeLength;

    @ApiModelProperty(value = "保留位")
    private String reservedBit;



    @ApiModelProperty(value = "创建人")
    @TableField(fill = FieldFill.INSERT)
    private Long creator;

    @ApiModelProperty(value = "修改人")
    @TableField(fill = FieldFill.INSERT_UPDATE)
    private Long updater;

    @ApiModelProperty(value = "创建时间")
    private LocalDateTime createTime;

    @ApiModelProperty(value = "更新时间")
    private LocalDateTime updateTime;

    @ApiModelProperty(value = "逻辑删除 (默认0 未删除 1删除)")
    private Integer deleted;


}
